package com.shamar.blog.enums;

/**
 * @author runquanchen
 * @version 1.0
 * @date 2020-01-22 22:32
 * @project channel
 */
public enum ThirdStatusEnum {

    PROCESS(1,"处理中"),

    SUCCESS(2,"成功"),

    FAIL(3,"失败"),


    RETRY_APPLY(4,"通联待重新申请"),

    RETRY_SUBMIT(5,"通联待重新提交明细"),

    RETRY_EXEC(6,"通联待重新执行申请"),

    APPLY_QRY(7,"通联待申请查询"),

    EXEC_QRY(8,"通联待执行查询");





    private int status;
    private String desc;

    ThirdStatusEnum(int code, String desc) {
        this.status = code;
        this.desc = desc;
    }

    public int getStatus() {
        return status;
    }

    public String getDesc() {
        return desc;
    }


    public static ThirdStatusEnum getByCode(int code) {
        for (ThirdStatusEnum anEnum : ThirdStatusEnum.values()) {
            if (anEnum.getStatus() == code) {
                return anEnum;
            }
        }
        return null;
    }
}
